package com.wdg.common.userInfo;

public class CurrentUserInfo {
    private static ThreadLocal<UserInfo> userInfoThreadLocal = new ThreadLocal();;

    public static UserInfo getUserInfo() {
        return userInfoThreadLocal.get();
    }

    public static void setUserInfo(UserInfo userInfo) {
        CurrentUserInfo.userInfoThreadLocal.set(userInfo);
    }

    public static void removeUserInfo(){
       userInfoThreadLocal.remove();
    }
}
